package com.cmc.cloud.cmclink.doc.vo.voyagebsacbavo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * Class-based Allocation分类舱位 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 *
 * @author codegen
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class VoyageBsaCbaBaseVO {

    @Schema(description = "舱位主信息id", requiredMode = Schema.RequiredMode.REQUIRED, example = "25479")
    @NotNull(message = "｛VoyageBsaCbaBaseVO.voyageBsaId.NotNull｝")
    private Long voyageBsaId;

    @Schema(description = "舱位类型代码", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotBlank(message = "｛VoyageBsaCbaBaseVO.spaceTypeCode.NotBlank｝")
    @Length(max = 20, message = "｛VoyageBsaCbaBaseVO.spaceTypeCode.Length｝")
    private String spaceTypeCode;

    @Schema(description = "舱位说明", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotBlank(message = "｛VoyageBsaCbaBaseVO.spaceIntruction.NotBlank｝")
    @Length(max = 50, message = "｛VoyageBsaCbaBaseVO.spaceIntruction.Length｝")
    private String spaceIntruction;

    @Schema(description = "分配舱位(teu)", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "{VoyageBsaCbaBaseVO.allocationSpace.NotNull}")
    private Integer allocationSpace;

    @Schema(description = "剩余舱位(teu)")
    private Integer remainAllocationSpace;

    @Schema(description = "冷插数")
    @NotNull(message = "{VoyageBsaCbaBaseVO.rfUnit.NotNull}")
    private Integer rfUnit;

    @Schema(description = "剩余冷插数")
    private Integer remainRfUnit;

    @Schema(description = "单客户TEU上线配置")
    private Integer perCustomerLimit;

}
